package com.wlr.blog.controller;


import com.wlr.blog.service.ICategoryService;
import com.wlr.blog.service.impl.CategoryServiceImpl;
import com.wlr.blog.util.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author wlr
 * @since 2021-07-29
 */
@RestController
@RequestMapping("/blog/category")
public class CategoryController {
    @Autowired
    ICategoryService categoryService;
    @RequestMapping
    public Result getCategory(){
        return Result.success(categoryService.list());
    }
}
